<%@ page contentType="text/html;charset=UTF-8"%>
<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html lang="en">
	<head>
	</head>
	<form id="saveForm" method="post" action="${r'${pageContext.request.contextPath}'}/${className?uncap_first}/save.htm">
	<body>
		<#list attrs as a>
			<#if a.primary?contains("TRUE")>
			<%--
				<input type="hidden" name="${a.columnName!}" id="${a.columnName!}" value="${r'${obj.'}${a.columnName!}${r'}'}"/>
				--%>
			</#if>
		</#list>
		<table class="table_all" align="center" border="0" cellpadding="0" cellspacing="0">
			<#list attrs as a> 
			<#if a.primary?contains("FALSE")>
		    	<tr>
				<td>
					<span>${a.columnComment!}：</span>
				</td>
				<td>
					<#if a.dataType?contains("Date")>
					<input name="${a.columnName!}" id="${a.columnName!}" value="<fmt:formatDate value="${r'${'}${className}${r'.'}${a.columnName!}${r'}'}" pattern="yyyy-MM-dd HH:mm:ss"/>" />
					<#else>
					<input name="${a.columnName!}" id="${a.columnName!}" value="${r'${'}${className}${r'.'}${a.columnName!}${r'}'}" />
					</#if>
				</td>
			</tr>
			</#if>
		    </#list>
		    <tr>
		    	<td colspan="${attrs?size}"><a onclick="submit()" style="{cursor:hand;}">确认</a></td>
		    </tr>
		</table>
	</body>
	</form>
	<script type="text/javascript">
		function submit(){
			$("#saveForm").submit();
			window.parent.layer.closeAll();
			window.parent.layer.msg("提交成功",'','');
		}
	</script>
</html>
